package com.jie.deletefile.Listview;

import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;

import com.jie.deletefile.R;

public class LvActivity extends AppCompatActivity implements View.OnClickListener {

    private Button lv_btn1;
    private Button lv_btn2;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_lv);
        initView();
    }

    private void initView() {
        lv_btn1 = (Button) findViewById(R.id.lv_btn1);

        lv_btn1.setOnClickListener(this);
        lv_btn2 = (Button) findViewById(R.id.lv_btn2);
        lv_btn2.setOnClickListener(this);
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.lv_btn1:
                Intent intent = new Intent(LvActivity.this, ShaActivity.class);
                startActivity(intent);
                break;
            case R.id.lv_btn2:
                Intent intent1 = new Intent(LvActivity.this, ErshaActivity.class);
                startActivity(intent1);
                break;
        }
    }
}
